package ui.perspective;

import org.eclipse.ui.IFolderLayout;
import org.eclipse.ui.IPageLayout;
import org.eclipse.ui.IPerspectiveFactory;

public class MarketVariablePerspective implements IPerspectiveFactory {
	
	public static final String ID = "com.eugene.ui.perspective.MarketVariable";
	@Override
	public void createInitialLayout(IPageLayout layout) {
		String editorArea = layout.getEditorArea();
		layout.setEditorAreaVisible(true);
        layout.setFixed( false );
        
        IFolderLayout leftFolder=layout.createFolder( ID + ".leftFolder", IPageLayout.LEFT, 0.4f, editorArea );
        IFolderLayout rightFolder = layout.createFolder( ID +".rightFolder", IPageLayout.RIGHT, 0.6f, editorArea );
        IFolderLayout bottomFolder = layout.createFolder(ID +".bottomFolder", IPageLayout.BOTTOM, 0.5f, editorArea );
        
		leftFolder.addPlaceholder("*.MarketVariableView*:*");
		leftFolder.addView("com.eugene.ui.views.MarketVariable");
		rightFolder.addPlaceholder("*.ScenarioView*:*");
		rightFolder.addView("com.eugene.ui.views.Scenario");
		
		bottomFolder.addPlaceholder("*Property*:*");
		bottomFolder.addView("com.eugene.ui.views.MarketVariableProperty");
		bottomFolder.addView("com.eugene.ui.views.ScenarioProperty");
//		bottomFolder.addView("org.eclipse.ui.views.PropertySheet");
//		bottomFolder.addView("com.eugene.ui.views.TestView");
		
//		Hide ActionSet
//		IWorkbenchPage page =PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
//		page.hideActionSet("org.eclipse.ui.edit.text.actionSet.navigation");
//	    page.hideActionSet("org.eclipse.ui.edit.text.actionSet.annotationNavigation");
		
		
	}
}
